package com.team7.happycommunity.propertymanagement.dao;

import com.team7.happycommunity.propertymanagement.pojo.PropertyManage;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

public interface PropertyManageMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(PropertyManage record);

    int insertSelective(PropertyManage record);

    PropertyManage selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(PropertyManage record);

    int updateByPrimaryKey(PropertyManage record);

    @Select("select * from property_manage where username = #{username}")
    PropertyManage selectByUserName(String username);

    @Update("update property_manage set password = #{newpass} where username = #{username}")
    int updatePWDByUsername(@Param(value = "newpass") String newpass,@Param(value = "username") String username);
}